<input 
(keyup.enter)="createPost(title)" #title
type="text" class="form-control">
<ul class="list-group">
  <li 
    class="list-group-item" *ngFor="let post of posts">
      <button (click)="updatePost(post)" class="btn btn-defalut btn-sm">Update</button>
      <button (click)="deletePost(post)" class="btn btn-defalut btn-sm">delete</button>
      {{ post.title }}
  </li>
</ul>
